package com.wanlian.netty.msg.Device;


import com.wanlian.util.QueueUtil;

import java.util.List;

/**
 * 处理各个设备的链接队列
 */
public class RequestServerMsgQueue {
    private static QueueUtil<RequestServerModel> queue = new QueueUtil<RequestServerModel>();

    public static synchronized void add(RequestServerModel model) {
        queue.add(model);
    }

    public static synchronized RequestServerModel get() {
        return queue.get();
    }

    public static synchronized List<RequestServerModel> get(int count) {
        return queue.get(count);
    }

    public static synchronized long size() {
        return queue.size();
    }
}
